<?php
//表单验证部分正则表达式
return array(
	'require'=> '/.*/', //匹配任意字符，除了空和断行符
	'email' => '/^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/',
	'phone' => '/^(0?\d{2,3}-?)?\d{5,9}$/',
	'mobile' => '/^((\(\d{2,3}\))|(\d{3}\-))?(1[0-9])\d{9}$/',
	'url' => '/^http[s]?:\/\/[A-Za-z0-9]+\.[A-Za-z0-9]+[\/=\?%\-&_~`@[\]\':+!]*([^<>\"\"])*$/',
	'currency' => '/^\d+(\.\d+)?$/',
	'number' => '/\d+$/',
	'zip' => '/^[1-9]\d{5}$/',
	'qq' => '/^[1-9]\d{4,12}$/',
	'integer' => '/^[-\+]?\d+$/',
	'double' => '/^[-\+]?\d+(\.\d+)?$/',
	'english' => '/^[A-Za-z]+$/',
    'string' => '/^[A-Za-z_]+[0-9_a-zA-Z]*$/',
	'dir' => '/^[A-Za-z_]+[0-9_a-zA-Z\/]*$/',
	'username' => '/^[A-Za-z_]+[0-9_a-zA-Z]*[0-9a-zA-Z]+$/',
    'ip' => '/^(\d+)\.(\d+)\.(\d+)\.(\d+)$/',
	'card' =>'/^(\d{14}|\d{17})(\d|[xX])$/',
	'image' => '/^.*\.(gif|jpg|jpeg|bmp|png)$/i',
	'sku'	=> '/^[0-9]{1}(\d{11,12}|\d{7})$/',
	'phone_mobile' => '/((\d{11})|^((\d{7,8})|(\d{4}|\d{3})-(\d{7,8})|(\d{4}|\d{3})-(\d{7,8})-(\d{4}|\d{3}|\d{2}|\d{1})|(\d{7,8})-(\d{4}|\d{3}|\d{2}|\d{1}))$)/',
);
?>